﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace KQ.DCMMP.Common
{
    public static class DefaultColumnTypes
    {
        public const string Primary = "PRIMARY";
        public const string Foreign = "FOREIGN";
        public const string Dictionary = "DICTIONARY";
        public const string Creator = "CREATOR";
        public const string CreateTime = "CREATETIME";
        public const string Modifier = "MODIFIER";
        public const string ModifyTime = "MODIFYTIME";
        public const string Organization = "ORG";
        public const string Delete = "DELETE";
        public const string Boolean = "BOOLEAN";
        public const string Division = "DIVISION";
        public const string Name = "NAME";
        public const string Code = "CODE";
        public const string Parent = "PARENT";
        public const string State = "STATE";
        public const string Text = "TEXT";
        public const string Integer = "INTEGER";
        public const string Decimal = "DECIMAL";

        public static bool IsPrimary(string extensionType)
        {
            return string.Equals(extensionType, Primary, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsForeign(string extensionType)
        {
            return string.Equals(extensionType, Foreign, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsDictionary(string extensionType)
        {
            return string.Equals(extensionType, Dictionary, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsCreator(string extensionType)
        {
            return string.Equals(extensionType, Creator, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsCreateTime(string extensionType)
        {
            return string.Equals(extensionType, CreateTime, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsModifier(string extensionType)
        {
            return string.Equals(extensionType, Modifier, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsModifyTime(string extensionType)
        {
            return string.Equals(extensionType, ModifyTime, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsDelete(string extensionType)
        {
            return string.Equals(extensionType, Delete, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsOrganization(string extensionType)
        {
            return string.Equals(extensionType, Organization, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsBoolean(string extensionType)
        {
            return string.Equals(extensionType, Boolean, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsDivision(string extensionType)
        {
            return string.Equals(extensionType, Division, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsName(string extensionType)
        {
            return string.Equals(extensionType, Name, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsCode(string extensionType)
        {
            return string.Equals(extensionType, Code, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsParent(string extensionType)
        {
            return string.Equals(extensionType, Parent, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsState(string extensionType)
        {
            return string.Equals(extensionType, State, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsText(string extensionType)
        {
            return string.Equals(extensionType, Text, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsInteger(string extensionType)
        {
            return string.Equals(extensionType, Integer, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsDecimal(string extensionType)
        {
            return string.Equals(extensionType, Decimal, StringComparison.OrdinalIgnoreCase);
        }
    }
}
